package com.power.test;

import com.power.common.model.CommonResult;
import com.power.test.model.Student;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 测试接口文档生成
 * @author yu 2021/4/26.
 */
@RestController
@RequestMapping(value = "app")
public class AppController {

    /**
     * 获取老师
     * @param teacher
     * @return
     */
    @PostMapping(value = "teacher")
    public CommonResult<Teacher> getTeacher(@RequestBody Teacher teacher){
        return CommonResult.ok();
    }

    /**
     * 添加学生信息
     * @param student
     * @return
     */
    @PostMapping("/student/add")
    public CommonResult addStudent(@RequestBody Student student){
        return CommonResult.ok();
    }
}
